package org.zcl.sqlSession;

import java.beans.IntrospectionException;
import java.lang.reflect.InvocationTargetException;
import java.sql.SQLException;
import java.util.List;

/**
 * .
 *
 * @Author Chenglin Zhu
 * @Date 2022/3/12 18:33
 */
public interface SqlSession {

    <E> List<E> selectList(String statementId, Object... params) throws SQLException, ClassNotFoundException, IntrospectionException, NoSuchFieldException, InvocationTargetException, IllegalAccessException, InstantiationException;

    <T> T selectOne(String statementId, Object... params) throws SQLException, ClassNotFoundException, IntrospectionException, NoSuchFieldException, InvocationTargetException, IllegalAccessException, InstantiationException;

    // 为dao接口生成代理实现类
    <T> T getMapper(Class<?> mapperClass);
}
